PROJECT_HOME=../../
OBJS= main.o mandelbaum.o \
	  $(PROJECT_HOME)/online-certifier/communicator/communicatorUtil.o \
      $(PROJECT_HOME)/online-certifier/communicator/decoderCommunicator.o

LDFLAGS= -lgmp -lgmpxx 
CXXFLAGS= -c -g -I$(PROJECT_HOME)
CC = g++

all: main

main: $(OBJS)
	$(CC)  -o decoder $(OBJS) $(LDFLAGS)
	cp decoder ../bin/
	cp decoder.conf ../bin/

main.o: main.cpp mandelbaum.h
	$(CC) $(CXXFLAGS) main.cpp  mandelbaum.h

mandelbaum.o: mandelbaum.cpp mandelbaum.h
	$(CC) $(CXXFLAGS) mandelbaum.cpp mandelbaum.h 

clean:
	rm *.o *.gch decoder
